package com.yunqing.restkeeper.store.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yunqing.restkeeper.service.common.redis.MybatisRedisCache;
import com.yunqing.restkeeper.store.api.entity.Staff;
import org.apache.ibatis.annotations.CacheNamespace;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * @ClassName StaffMapper
 * @Description TODO
 * @author: puyunqing
 * @Date: 2025/7/21
 */
@Mapper
@CacheNamespace(implementation = MybatisRedisCache.class, eviction = MybatisRedisCache.class)
public interface StaffMapper extends BaseMapper<Staff> {

    @Select("select * from t_staff where shop_id=#{shopId} and staff_name=#{loginName}")
    Staff login(@Param("shopId") String shopId, @Param("loginName") String loginName);

}
